package cn.zktr.Personnel.model.pojos;

import java.io.Serializable;
import javax.persistence.*;
import java.sql.Timestamp;
import java.util.List;


/**
 * The persistent class for the per_cwa_cwas database table.
 * 
 */
@Entity
@Table(name="per_cwa_cwas")
@NamedQuery(name="PerCwaCwas.findAll", query="SELECT p FROM PerCwaCwas p")
public class PerCwaCwas implements Serializable {
	private static final long serialVersionUID = 1L;

	@Id
	private int cwasid;

	private String cwasrem;

	private Timestamp cwastime;

	//bi-directional many-to-one association to PerCwaRsn
	@ManyToOne
	@JoinColumn(name="RSNID")
	private PerCwaRsn perCwaRsn;

	//bi-directional many-to-one association to PerCwaShf
	@ManyToOne
	@JoinColumn(name="SHFID")
	private PerCwaShf perCwaShf;

	//bi-directional many-to-one association to PerCwaTem
	@ManyToOne
	@JoinColumn(name="TEMID")
	private PerCwaTem perCwaTem;

	//bi-directional many-to-one association to PerPmsDept
	@ManyToOne
	@JoinColumn(name="DEPTID")
	private PerPmsDept perPmsDept;

	//bi-directional many-to-one association to PerPmsEmp
	@ManyToOne
	@JoinColumn(name="EMPID")
	private PerPmsEmp perPmsEmp;

	//bi-directional many-to-one association to PerCwaFid
	@OneToMany(mappedBy="perCwaCwa")
	private List<PerCwaFid> perCwaFids;

	//bi-directional many-to-one association to PerCwaKpr
	@OneToMany(mappedBy="perCwaCwa")
	private List<PerCwaKpr> perCwaKprs;

	//bi-directional many-to-one association to PerCwaQLae
	@OneToMany(mappedBy="perCwaCwa")
	private List<PerCwaQLae> perCwaQLaes;

	//bi-directional many-to-one association to PerCwaQts
	@OneToMany(mappedBy="perCwaCwa")
	private List<PerCwaQts> perCwaQts;

	//bi-directional many-to-one association to PerCwaRes
	@OneToMany(mappedBy="perCwaCwa")
	private List<PerCwaRes> perCwaRes;

	//bi-directional many-to-one association to PerCwaSst
	@OneToMany(mappedBy="perCwaCwa1")
	private List<PerCwaSst> perCwaSsts1;

	//bi-directional many-to-one association to PerCwaSst
	@OneToMany(mappedBy="perCwaCwa2")
	private List<PerCwaSst> perCwaSsts2;

	public PerCwaCwas() {
	}

	public int getCwasid() {
		return this.cwasid;
	}

	public void setCwasid(int cwasid) {
		this.cwasid = cwasid;
	}

	public String getCwasrem() {
		return this.cwasrem;
	}

	public void setCwasrem(String cwasrem) {
		this.cwasrem = cwasrem;
	}

	public Timestamp getCwastime() {
		return this.cwastime;
	}

	public void setCwastime(Timestamp cwastime) {
		this.cwastime = cwastime;
	}

	public PerCwaRsn getPerCwaRsn() {
		return this.perCwaRsn;
	}

	public void setPerCwaRsn(PerCwaRsn perCwaRsn) {
		this.perCwaRsn = perCwaRsn;
	}

	public PerCwaShf getPerCwaShf() {
		return this.perCwaShf;
	}

	public void setPerCwaShf(PerCwaShf perCwaShf) {
		this.perCwaShf = perCwaShf;
	}

	public PerCwaTem getPerCwaTem() {
		return this.perCwaTem;
	}

	public void setPerCwaTem(PerCwaTem perCwaTem) {
		this.perCwaTem = perCwaTem;
	}

	public PerPmsDept getPerPmsDept() {
		return this.perPmsDept;
	}

	public void setPerPmsDept(PerPmsDept perPmsDept) {
		this.perPmsDept = perPmsDept;
	}

	public PerPmsEmp getPerPmsEmp() {
		return this.perPmsEmp;
	}

	public void setPerPmsEmp(PerPmsEmp perPmsEmp) {
		this.perPmsEmp = perPmsEmp;
	}

	public List<PerCwaFid> getPerCwaFids() {
		return this.perCwaFids;
	}

	public void setPerCwaFids(List<PerCwaFid> perCwaFids) {
		this.perCwaFids = perCwaFids;
	}

	public PerCwaFid addPerCwaFid(PerCwaFid perCwaFid) {
		getPerCwaFids().add(perCwaFid);
		perCwaFid.setPerCwaCwa(this);

		return perCwaFid;
	}

	public PerCwaFid removePerCwaFid(PerCwaFid perCwaFid) {
		getPerCwaFids().remove(perCwaFid);
		perCwaFid.setPerCwaCwa(null);

		return perCwaFid;
	}

	public List<PerCwaKpr> getPerCwaKprs() {
		return this.perCwaKprs;
	}

	public void setPerCwaKprs(List<PerCwaKpr> perCwaKprs) {
		this.perCwaKprs = perCwaKprs;
	}

	public PerCwaKpr addPerCwaKpr(PerCwaKpr perCwaKpr) {
		getPerCwaKprs().add(perCwaKpr);
		perCwaKpr.setPerCwaCwa(this);

		return perCwaKpr;
	}

	public PerCwaKpr removePerCwaKpr(PerCwaKpr perCwaKpr) {
		getPerCwaKprs().remove(perCwaKpr);
		perCwaKpr.setPerCwaCwa(null);

		return perCwaKpr;
	}

	public List<PerCwaQLae> getPerCwaQLaes() {
		return this.perCwaQLaes;
	}

	public void setPerCwaQLaes(List<PerCwaQLae> perCwaQLaes) {
		this.perCwaQLaes = perCwaQLaes;
	}

	public PerCwaQLae addPerCwaQLae(PerCwaQLae perCwaQLae) {
		getPerCwaQLaes().add(perCwaQLae);
		perCwaQLae.setPerCwaCwa(this);

		return perCwaQLae;
	}

	public PerCwaQLae removePerCwaQLae(PerCwaQLae perCwaQLae) {
		getPerCwaQLaes().remove(perCwaQLae);
		perCwaQLae.setPerCwaCwa(null);

		return perCwaQLae;
	}

	public List<PerCwaQts> getPerCwaQts() {
		return this.perCwaQts;
	}

	public void setPerCwaQts(List<PerCwaQts> perCwaQts) {
		this.perCwaQts = perCwaQts;
	}

	public PerCwaQts addPerCwaQt(PerCwaQts perCwaQt) {
		getPerCwaQts().add(perCwaQt);
		perCwaQt.setPerCwaCwa(this);

		return perCwaQt;
	}

	public PerCwaQts removePerCwaQt(PerCwaQts perCwaQt) {
		getPerCwaQts().remove(perCwaQt);
		perCwaQt.setPerCwaCwa(null);

		return perCwaQt;
	}

	public List<PerCwaRes> getPerCwaRes() {
		return this.perCwaRes;
	}

	public void setPerCwaRes(List<PerCwaRes> perCwaRes) {
		this.perCwaRes = perCwaRes;
	}

	public PerCwaRes addPerCwaRe(PerCwaRes perCwaRe) {
		getPerCwaRes().add(perCwaRe);
		perCwaRe.setPerCwaCwa(this);

		return perCwaRe;
	}

	public PerCwaRes removePerCwaRe(PerCwaRes perCwaRe) {
		getPerCwaRes().remove(perCwaRe);
		perCwaRe.setPerCwaCwa(null);

		return perCwaRe;
	}

	public List<PerCwaSst> getPerCwaSsts1() {
		return this.perCwaSsts1;
	}

	public void setPerCwaSsts1(List<PerCwaSst> perCwaSsts1) {
		this.perCwaSsts1 = perCwaSsts1;
	}

	public PerCwaSst addPerCwaSsts1(PerCwaSst perCwaSsts1) {
		getPerCwaSsts1().add(perCwaSsts1);
		perCwaSsts1.setPerCwaCwa1(this);

		return perCwaSsts1;
	}

	public PerCwaSst removePerCwaSsts1(PerCwaSst perCwaSsts1) {
		getPerCwaSsts1().remove(perCwaSsts1);
		perCwaSsts1.setPerCwaCwa1(null);

		return perCwaSsts1;
	}

	public List<PerCwaSst> getPerCwaSsts2() {
		return this.perCwaSsts2;
	}

	public void setPerCwaSsts2(List<PerCwaSst> perCwaSsts2) {
		this.perCwaSsts2 = perCwaSsts2;
	}

	public PerCwaSst addPerCwaSsts2(PerCwaSst perCwaSsts2) {
		getPerCwaSsts2().add(perCwaSsts2);
		perCwaSsts2.setPerCwaCwa2(this);

		return perCwaSsts2;
	}

	public PerCwaSst removePerCwaSsts2(PerCwaSst perCwaSsts2) {
		getPerCwaSsts2().remove(perCwaSsts2);
		perCwaSsts2.setPerCwaCwa2(null);

		return perCwaSsts2;
	}

}